<template>
	<view class="content-box">
		<view class="fixed">
			<view class="content1">
				<Head></Head>
			</view>
			<view class="content2">
				<Banner></Banner>
			</view>
		</view>
		<div class="main-center">
		      <h1>{{obj.title}}</h1>
		      <p v-html="obj.content"></p>
		    </div>
				<foot></foot>
	</view>
</template>

<script>
	import Head from '@/components/head.vue'
	import Banner from '@/components/banner.vue'
	import Foot from '@/components/foot.vue'
	export default {
		components: {
			Head,
			Banner,
			Foot
		},
		data() {
			return {
				obj:{}
			};
		},
		onLoad(e) {
			console.log(e.id)
			uni.request({
				url:'http://nj.donglianguoji.com/index/getNewsDetail?id=' + e.id,
				method:'GET',
				success: (res) => {
					console.log(res.data)
					this.obj=res.data
				}
			})
		}
	}
</script>

<style lang="scss">
.main-center{
  max-width: 1200px;
  margin: 0 auto;
  padding: 200px 0 100px 0;
}
h1{margin-bottom: 30px;}
@media screen and (max-width: 750px){
	.main-center{
	  margin: auto 20px ;
	  padding: 80px 0 100px 0;
	}
}
</style>
